package com.bdmc.device.domain.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.bdmc.common.annotation.ExcelDictFormat;
import com.bdmc.common.convert.ExcelDictConvert;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.time.LocalDateTime;

;

/**
 * 实时位置信息视图对象 dev_gps_realtime
 *
 * @author bdmc
 * @date 2022-03-22
 */
@Data
@ExcelIgnoreUnannotated
public class DevGpsRealtimeVo {

	private static final long serialVersionUID = 1L;

    /**
     * 
     */
	@ExcelProperty(value = "")
	private Long realtimeId;

    /**
     * 设备id
     */
	@ExcelProperty(value = "设备id")
	private Long deviceId;

    /**
     * 设备808通讯号
     */
	@ExcelProperty(value = "设备808通讯号")
	private String devicePhoneNum;

    /**
     * 纬度
     */
	@ExcelProperty(value = "纬度")
	private String lat;

    /**
     * 经度
     */
	@ExcelProperty(value = "经度")
	private String lng;

    /**
     * 定位数据上报时间
     */
	@ExcelProperty(value = "定位数据上报时间")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime dataTime;

    /**
     * 是否在线 1=在线，2=离线
     */
	@ExcelProperty(value = "是否在线 1=在线，2=离线")
	private Integer onlineStatus;

    /**
     * 报警类型编码
     */
	@ExcelProperty(value = "报警类型编码")
	private Integer alarmCode;

    /**
     * 报警类型字符串逗号拼接
     */
	@ExcelProperty(value = "报警类型字符串逗号拼接")
	private String alarmType;

    /**
     * 高度
     */
	@ExcelProperty(value = "高度")
	private Integer hight;

    /**
     * 速度
     */
	@ExcelProperty(value = "速度")
	private BigDecimal speed;

    /**
     * 0-360
     */
	@ExcelProperty(value = "0-360")
	private Integer direction;

    /**
     * 里程
     */
	@ExcelProperty(value = "里程")
	private Long mileage;

    /**
     * 油量
     */
	@ExcelProperty(value = "油量")
	private String oilMass;

    /**
     * 电压等级，00：无电（关机）01：电量极低（不足以打电话发短信等）02：点亮很低（低电报警）03：电量低（可正常使用）04：电量中05：电量高06：电量极高
     */
	@ExcelProperty(value = "电压等级，00：无电", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "关=机")
	private Integer voltageLevel;

    /**
     * 信号强度00：无信号01：信号极弱02：信号较弱03：信号良好04：信号强
     */
	@ExcelProperty(value = "信号强度00：无信号01：信号极弱02：信号较弱03：信号良好04：信号强")
	private Integer gsmSignal;

    /**
     * 设备状态，油电，定位
     */
	@ExcelProperty(value = "设备状态，油电，定位")
	private String devState;

    /**
     * 车辆位置
     */
	@ExcelProperty(value = "车辆位置")
	private String carLocation;

	private String personName;

	private String mobile;

	private String personType;

	private String offlineIcon;

	private String onlineIcon;

	private String alarmIcon;

	private String carNum;

	private String carType;

	private String deptName;

	private Short inWorkTime;

	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime createTime;
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime updateTime;

	private String wgs84Lat;

	private String wgs84Lng;
}
